<?php /*a:4:{s:113:"/www/wwwroot/dianshu/application/admin/view/default/../../../plugins/view/expressforkdn/index/public/content.html";i:1568885128;s:107:"/www/wwwroot/dianshu/application/admin/view/default/../../../plugins/view/coupon/admin/coupon/sendinfo.html";i:1570967780;s:70:"/www/wwwroot/dianshu/application/admin/view/default/public/header.html";i:1568774834;s:70:"/www/wwwroot/dianshu/application/admin/view/default/public/footer.html";i:1572600796;}*/ ?>
<!DOCTYPE html>
<html>
<head>
	<meta charset="<?php echo config('shopxo.default_charset', 'utf-8'); ?>" />
	<link rel="shortcut icon" type="image/x-icon" href="favicon.ico" />
	<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1, maximum-scale=1" />
	<title>ShopXO后台管理系统</title>
	<link rel="stylesheet" type="text/css" href="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/lib/assets/css/amazeui.css" />
	<link rel="stylesheet" type="text/css" href="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/lib/amazeui-switch/amazeui.switch.css" />
	<link rel="stylesheet" type="text/css" href="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/lib/amazeui-chosen/amazeui.chosen.css" />
	<link rel="stylesheet" type="text/css" href="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/lib/amazeui-tagsinput/amazeui.tagsinput.css" />
	<link rel="stylesheet" type="text/css" href="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/css/common.css" />
	<link rel="stylesheet" type="text/css" href="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/admin/<?php echo htmlentities($default_theme); ?>/css/common.css" />
	<link rel="stylesheet" type="text/css" href="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/admin/<?php echo htmlentities($default_theme); ?>/css/iconfontmenu.css" />
    <?php if(!empty($plugins_css)): ?>
        <link rel="stylesheet" type="text/css" href="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/<?php echo htmlentities($plugins_css); ?>" />
    <?php endif; if(!empty($module_css)): ?>
		<link rel="stylesheet" type="text/css" href="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/<?php echo htmlentities($module_css); ?>" />
	<?php endif; ?>

	<!-- css钩子 -->
    <?php if(!empty($plugins_admin_css_data) and is_array($plugins_admin_css_data)): foreach($plugins_admin_css_data as $hook): if(is_string($hook)): ?>
                <link rel="stylesheet" type="text/css" href="<?php echo htmlentities($hook); ?>?v=<?php echo MyC('home_static_cache_version'); ?>" />
            <?php elseif(is_array($hook)): foreach($hook as $hook_css): if(is_string($hook_css)): ?>
                        <link rel="stylesheet" type="text/css" href="<?php echo htmlentities($hook_css); ?>?v=<?php echo MyC('home_static_cache_version'); ?>" />
                    <?php endif; ?>
                <?php endforeach; ?>
            <?php endif; ?>
        <?php endforeach; ?>
    <?php endif; ?>

    <!-- 公共header内钩子 -->
	<?php if(!empty($plugins_admin_common_header_data) and is_array($plugins_admin_common_header_data)): foreach($plugins_admin_common_header_data as $hook): if(is_string($hook) or is_int($hook)): ?>
				<?php echo $hook; ?>
			<?php endif; ?>
		<?php endforeach; ?>
	<?php endif; ?>
</head>
<script type="text/javascript">
	var __attachment_host__ = '<?php echo htmlentities($attachment_host); ?>';
</script>
<body>
<!-- 公共顶部钩子 -->
<?php if(!empty($plugins_admin_view_common_top_data) and is_array($plugins_admin_view_common_top_data) and (!isset($is_header) or $is_header == 1)): foreach($plugins_admin_view_common_top_data as $hook): if(is_string($hook) or is_int($hook)): ?>
			<?php echo $hook; ?>
		<?php endif; ?>
	<?php endforeach; ?>
<?php endif; ?>

<!-- right content start  -->
<div class="content-right">
    <div class="content">
        <legend>
            <span class="fs-16">优惠劵发放</span>
            <a href="<?php echo PluginsAdminUrl('coupon', 'coupon', 'index', $params); ?>" class="fr fs-14 m-t-5 am-icon-mail-reply"> 返回</a>
        </legend>

        <?php if(!empty($data)): ?>
            <!-- form start -->
            <form class="am-form form-validation view-save" action="<?php echo PluginsAdminUrl('coupon', 'coupon', 'send'); ?>" method="POST" request-type="ajax-url" request-value="<?php echo PluginsAdminUrl('coupon', 'coupon', 'index', $params); ?>">
                <!-- 优惠劵信息 -->
                <div class="am-panel am-panel-default">
                    <div class="am-panel-hd">优惠劵信息</div>
                    <div class="am-panel-bd">
                        <dl class="dl-content">
                            <dt>名称</dt>
                            <dd>
                                <?php echo htmlentities($data['name']); ?>
                                <span class="am-badge am-radius <?php if($data['type'] == 0): ?>am-badge-success<?php else: ?>am-badge-warning<?php endif; ?>"><?php echo htmlentities($data['type_name']); ?></span>
                            </dd>

                            <dt>描述</dt>
                            <dd><?php echo htmlentities($data['desc']); ?></dd>

                            <dt>过期类型</dt>
                            <dd>
                                <?php echo htmlentities($data['expire_type_name']); if($data['expire_type'] == 0): ?>
                                    <span class="am-badge am-radius">有效 <?php echo htmlentities($data['expire_hour']); ?> 小时</span>
                                <?php else: ?>
                                    <span class="am-badge am-radius"><?php echo htmlentities($data['fixed_time_start']); ?> ~ <?php echo htmlentities($data['fixed_time_end']); ?></span>
                                <?php endif; ?>
                            </dd>

                            <dt>使用限制</dt>
                            <dd>
                                <?php echo htmlentities($data['use_limit_type_name']); if($data['use_limit_type'] == 1): ?>
                                    <p class="am-text-warning">仅限关联的品类下使用</p>
                                <?php elseif($data['use_limit_type'] == 2): ?>
                                    <p class="am-text-warning">仅限关联的商品使用</p>
                                <?php endif; ?>
                            </dd>

                            <dt>优惠信息</dt>
                            <dd>
                                <?php if($data['type'] == 0): ?>
                                    减 <span class="am-text-success"><?php echo htmlentities($data['discount_value']); ?></span> 元
                                <?php else: ?>
                                    打 <span class="am-text-warning"><?php echo htmlentities($data['discount_value']); ?></span> 折
                                <?php endif; ?>
                            </dd>

                            <dt>发放限制</dt>
                            <dd>
                                <?php if($data['limit_send_count'] > 0): ?>
                                    最多发放 <span class="am-text-danger"><?php echo htmlentities($data['limit_send_count']); ?></span> 张
                                <?php else: ?>
                                    不限发放数量
                                <?php endif; if($data['already_send_count'] > 0): ?>
                                    <br />已发放<span class="am-text-success"><?php echo htmlentities($data['already_send_count']); ?></span>张
                                <?php endif; ?>
                            </dd>
                        </dl>
                    </div>
                </div>

                <!-- 搜索用户 -->
                <div class="am-panel am-panel-default not-user-panel">
                    <div class="am-panel-hd">搜索用户</div>
                    <div class="am-panel-bd">
                        <div class="am-input-group am-input-group-sm secondary user-search-container" data-search-url="<?php echo PluginsAdminUrl('coupon', 'coupon', 'usersearch'); ?>">
                            <input type="text" autocomplete="off" class="am-radius user-input-keywords" placeholder="用户名/昵称/手机/邮箱" value="">
                            <span class="am-input-group-btn">
                                <button class="am-btn am-btn-default am-radius" type="button">搜索</button>
                            </span>
                        </div>
                        <ul class="am-avg-sm-2 am-avg-md-6 am-avg-lg-10 user-items"></ul>
                        <div class="table-no"><i class="am-icon-warning"></i> 请输入关键字搜索用户</div>
                    </div>
                </div>

                <!-- 已选用户 -->
                <div class="am-panel am-panel-success already-user-panel">
                    <div class="am-panel-hd">已选用户</div>
                    <div class="am-panel-bd">
                        <ul class="am-avg-sm-2 am-avg-md-4 am-avg-lg-8 user-items"></ul>
                        <div class="table-no"><i class="am-icon-warning"></i> 没有选择用户</div>
                    </div>
                </div>

                <div class="am-form-group am-form-group-refreshing">
                    <input type="hidden" name="coupon_id" <?php if(!empty($data['id'])): ?> value="<?php echo htmlentities($data['id']); ?>"<?php endif; ?> />
                    <button type="submit" class="am-btn am-btn-primary am-radius btn-loading-example am-btn-sm am-btn-block" data-am-loading="{loadingText:'处理中...'}">发放</button>
                </div>
            </form>
            <!-- form end -->
        <?php else: ?>
            <div class="table-no"><i class="am-icon-warning"></i> 优惠劵操作id有误</div>
        <?php endif; ?>
    </div>
</div>
<!-- right content end  -->
        
<!-- footer start -->
<!-- commom html -->
<textarea id="upload-editor-view" data-url="<?php echo MyUrl('admin/ueditor/index', ['path_type'=>empty($editor_path_type) ? 'common' : $editor_path_type]); ?>" style="display: none;"></textarea>

<!-- 公共底部钩子 -->
<?php if(!empty($plugins_admin_view_common_bottom_data) and is_array($plugins_admin_view_common_bottom_data) and (!isset($is_footer) or $is_footer == 1)): foreach($plugins_admin_view_common_bottom_data as $hook): if(is_string($hook) or is_int($hook)): ?>
            <?php echo $hook; ?>
        <?php endif; ?>
    <?php endforeach; ?>
<?php endif; ?>

</body>
</html>

<!-- 类库 -->
<script type='text/javascript' src="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/lib/jquery/jquery-2.1.0.js"></script>
<script type='text/javascript' src="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/lib/assets/js/amazeui.min.js"></script>

<!-- echarts 图表 -->
<script type='text/javascript' src="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/lib/echarts/echarts.min.js"></script>
<script type='text/javascript' src="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/lib/echarts/macarons.js"></script>

<!-- ueditor 编辑器 -->
<script type='text/javascript' src="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/lib/ueditor/ueditor.config.js"></script>
<script type='text/javascript' src="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/lib/ueditor/ueditor.all.js"></script>
<script type='text/javascript' src="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/lib/ueditor/lang/zh-cn/zh-cn.js"></script>

<!-- 颜色选择器 -->
<script type='text/javascript' src="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/lib/colorpicker/jquery.colorpicker.js"></script>

<!-- 元素拖拽排序插件 -->
<script type='text/javascript' src="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/lib/dragsort/jquery.dragsort-0.5.2.min.js"></script>

<!-- 动画数数 -->
<script type='text/javascript' src="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/lib/animation-count-to/animation.count.to.js"></script>

<!-- amazeui插件 -->
<script type='text/javascript' src="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/lib/amazeui-switch/amazeui.switch.min.js"></script>
<script type='text/javascript' src="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/lib/amazeui-chosen/amazeui.chosen.min.js"></script>
<script type='text/javascript' src="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/lib/amazeui-dialog/amazeui.dialog.min.js"></script>
<script type='text/javascript' src="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/lib/amazeui-tagsinput/amazeui.tagsinput.min.js"></script>

<!-- 日期组件 -->
<script type='text/javascript' src="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/lib/My97DatePicker/WdatePicker.js"></script>

<!-- 元素拖动 -->
<script type='text/javascript' src="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/lib/tdrag/tdrag.min.js"></script>

<!-- 隐藏编辑器初始化 -->
<script type="text/javascript">
    var upload_editor = UE.getEditor("upload-editor-view", {
        isShow: false,
        focus: false,
        enableAutoSave: false,
        autoSyncData: false,
        autoFloatEnabled:false,
        wordCount: false,
        sourceEditor: null,
        scaleEnabled:true,
        toolbars: [["insertimage", "insertvideo", "attachment"]]
    });
</script>

<!-- 项目公共 -->
<script type='text/javascript' src="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/common/js/common.js"></script>

<!-- 应用插件公共js -->
<?php if(!empty($plugins_js)): ?>
    <script type='text/javascript' src="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/<?php echo htmlentities($plugins_js); ?>"></script>
<?php endif; ?>

<!-- 当前控制器js -->
<?php if(!empty($module_js)): ?>
    <script type='text/javascript' src="<?php echo htmlentities(__MY_ROOT_PUBLIC__); ?>static/<?php echo htmlentities($module_js); ?>"></script>
<?php endif; ?>

<!-- js钩子 -->
<?php if(!empty($plugins_admin_js_data) and is_array($plugins_admin_js_data)): foreach($plugins_admin_js_data as $hook): if(is_string($hook)): ?>
            <script type='text/javascript' src="<?php echo htmlentities($hook); ?>"></script>
        <?php elseif(is_array($hook)): foreach($hook as $hook_js): if(is_string($hook_js)): ?>
                    <script type='text/javascript' src="<?php echo htmlentities($hook_js); ?>"></script>
                <?php endif; ?>
            <?php endforeach; ?>
        <?php endif; ?>
    <?php endforeach; ?>
<?php endif; ?>

<!-- 公共页面底部钩子 -->
<?php if(!empty($plugins_admin_common_page_bottom_data) and is_array($plugins_admin_common_page_bottom_data)): foreach($plugins_admin_common_page_bottom_data as $hook): if(is_string($hook) or is_int($hook)): ?>
            <?php echo $hook; ?>
        <?php endif; ?>
    <?php endforeach; ?>
<?php endif; ?>
<!-- footer end -->